<template>
	<view>
		<button @tap="back">返回</button>
		详情
		<image :src="`https://elm.cangdu.org/img/${info.image_path}`" mode=""></image>
		<p>{{info.name}}</p>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				info:{}, // 商店详情
			}
		},
		methods: {
			back(){ // 返回
				uni.navigateBack()
			}
		},
		onLoad(options) {
			console.log(options);
			let {id} = options;
			uni.request({
				url:"http://elm.cangdu.org/shopping/restaurant/"+ id
			}).then(res=>{
				console.log(res);
				this.info = res[1].data;
			})
		}
	}
</script>

<style>

</style>
